﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace NewRen.Models
{

    /// <summary>
    /// 区县
    /// </summary>
    public class District
    {
        public int ID { set; get; }


        [StringLength(30)]
        [Index]
        public string DistrictName { set; get; }

        /// <summary>
        /// 城市ID
        /// </summary>
        [ForeignKey("City")]
        public int CityID { set; get; }

        public virtual City City { set; get; }

    }
}
